donde puedo realizar consultas en HeidiSQl y almacenarlas para posteriores usos.

[expired user #5814]'s profile image [expired user #5814] posted 13 years ago in General Permalink
En Heidisql donde puedo hacer las consultas ya que soy nuevo les agradecería si me pudieran ayudar con un manual grafico de las funciones del programa detalladas de donde puedo realizar consultas,tigger, etc.
Ya se que que hay unos pantallazos con siertas funciones del programa pero no son muy claras.
En el siguiente ejemplo Me gustaría hacer una consulta que retorne la suma de CONTADO,ANTICIPO,C_INICIAL, C_EXTRA, M_C_ORD, INTERES, SEG_DIRECTO, SEGURO, DESEMBOLSO en una columna que se llamaría totaldia.
Pero no se donde hacerla y almacenarla.

CREATE TABLE `recaudo diario` (
`ID` INT(10) UNSIGNED NOT NULL AUTO_INCREMENT,
`FECHA` DATETIME NOT NULL,
`TIPO_CREDITO` ENUM('MOTOCOR DIRECTO','MOTOCOR ALIADAS','SABANA DIRECTO','SABANA ALIADAS') NOT NULL,
`CONTADO` FLOAT UNSIGNED NULL DEFAULT NULL,
`ANTICIPO` FLOAT UNSIGNED NULL DEFAULT NULL,
`C_INICIAL` FLOAT UNSIGNED NULL DEFAULT NULL,
`C_EXTRA` FLOAT UNSIGNED NULL DEFAULT NULL,
`M_C_ORD` FLOAT UNSIGNED NULL DEFAULT NULL,
`JURIDICO` VARCHAR(100) NULL DEFAULT NULL,
`INTERES` FLOAT UNSIGNED NULL DEFAULT NULL,
`SEG_DIRECTO` FLOAT UNSIGNED NULL DEFAULT NULL,
`SEGURO` FLOAT UNSIGNED NULL DEFAULT NULL,
`DESEMBOLSO` FLOAT UNSIGNED NULL DEFAULT NULL,
PRIMARY KEY (`ID`)
)
COMMENT='se ingresa el recaudo detallado de la cartera'
COLLATE='utf8_general_ci'
ENGINE=InnoDB
ROW_FORMAT=DEFAULT

ansgar's profile image ansgar posted 13 years ago Permalink
Können wir bitte bei Englisch bleiben? Mein Spanisch ist etwas eingerostet... eh, could we please stick to english? My spanish is not so good.
[expired user #5814]'s profile image [expired user #5814] posted 13 years ago Permalink
In HeidiSQL where I can do consultations and I am new I would be grateful if you could help me with a manual chart features detailed program where I can consult, tigger, and so on.
I know that there are some screenshots with siertas program functions but are not very clear.
In the following example I like to do a query that returns the sum of CASH, ADVANCE, C_INICIAL, C_EXTRA, M_C_ORD, INTEREST SEG_DIRECTO, SECURE, DISBURSEMENT in a column called totaldia.
But no where to do it and store it.

CREATE TABLE `recaudo diario` (
`ID` INT(10) UNSIGNED NOT NULL AUTO_INCREMENT,
`FECHA` DATETIME NOT NULL,
`TIPO_CREDITO` ENUM('MOTOCOR DIRECTO','MOTOCOR ALIADAS','SABANA DIRECTO','SABANA ALIADAS') NOT NULL,
`CONTADO` FLOAT UNSIGNED NULL DEFAULT NULL,
`ANTICIPO` FLOAT UNSIGNED NULL DEFAULT NULL,
`C_INICIAL` FLOAT UNSIGNED NULL DEFAULT NULL,
`C_EXTRA` FLOAT UNSIGNED NULL DEFAULT NULL,
`M_C_ORD` FLOAT UNSIGNED NULL DEFAULT NULL,
`JURIDICO` VARCHAR(100) NULL DEFAULT NULL,
`INTERES` FLOAT UNSIGNED NULL DEFAULT NULL,
`SEG_DIRECTO` FLOAT UNSIGNED NULL DEFAULT NULL,
`SEGURO` FLOAT UNSIGNED NULL DEFAULT NULL,
`DESEMBOLSO` FLOAT UNSIGNED NULL DEFAULT NULL,
PRIMARY KEY (`ID`)
)
COMMENT='se ingresa el recaudo detallado de la cartera'
COLLATE='utf8_general_ci'
ENGINE=InnoDB
ROW_FORMAT=DEFAULT


ansgar's profile image ansgar posted 13 years ago Permalink
SELECT SUM(CASH) FROM mytable
[expired user #5298]'s profile image [expired user #5298] posted 13 years ago Permalink
Hi,

Please read this,

http://stackoverflow.com/questions/508791/mysql-query-group-by-day-month-year
There is a data filter tab in heidisql, but it filters and does not run aggregation functions


Es mejor, saver antes como hacer las cosas en mysql. Despuses vas a entender si puedes hacer es con heidisql
Hasta luego,

Please login to leave a reply, or register at first.