Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    IamZeek
    @ziaur25
    I have no clue to write a coordinated delete query (deleting multiple tables in same query)
    prinxy
    @prinxy
    Hello room.. :smile:
    ghanmy
    @ghanmy
    Hello
    أحمد عاكف
    @ahmed_akef__twitter
    Hello
    Why sqlite isn't a server and every dbms else is a server ?
    Why we need do start this server and stop
    Why mysql isn't just files
    liondancer
    @liondancer
    I have 2 columns that have time data that looks like "2017-12-06 18:50:27 +0000" . What mysql function can I use to get the difference in HOURS of the 2 date time strings? I tried DATEDIFF(time_string_1, time_string_2) but it isn't working. What else can I use?
    aniltomar9
    @aniltomar9
    Hi any website where I can get all MySQL queries like trigger,cascade etc. Please share with..... Thanks
    吴晓兰
    @wuxiaolan91
    Hello,guys,
    I want connect mysql 8.9
    code:
    image.png
    but i get this error:
    image.png
    mysql 8.0, not 8.9
    marcko
    @marcko
    Hi Guys , I have the problem with mysql cluster.When insert or update data in some table with many registers. Get the error #1114 the table "xxx" is full. Has someone happened to you?
    Eatgrass
    @eatgrass
    @wuxiaolan91 try $ npm install @mysql/xdevapi this driver
    Sarit Vakrat
    @ActoMatics
    Hi, im using mysql-promise and when I close the pool the node process never closes, any ideas?
    mortalites
    @mortalites
    Hi everyone I havent used gitter much I need a little mysql help and Im not sure what Room to join
    mengxiaoyong
    @mengxiaoyong
    hello
    vijendra singh
    @viju0731_twitter
    hI
    image.png
    vijendra singh
    @viju0731_twitter
    how to add integer when 2 string collides
    any help
    Sandy
    @ethereal-sandeep

    This is my model.js

    module.exports.getUser = userId => {
      const sql = {
        sql: "SELECT * from user where user_id=?"
      };
      const sqlParams = [userId];
    
      connection.query(sql, sqlParams, (error, results, fields) => {
        // Handle error after the release.
        if (error) throw error;
        console.log(results);
        return results;
      });
    };

    this is my service.js

    module.exports.getUser = () => {
      let user = User.getUser(1);
      console.log(user);
      return user;
    };

    But in my service.js file its coming as undefined but in model.js (inside the callback) its printing the results correctly.

    how can i pass this results back to the calling method in service.js

    Sandy
    @ethereal-sandeep
    Please help
    Sandy
    @ethereal-sandeep
    Hi, i did that using Q library, anyone else has better approach
    Abhinav Taneja
    @abhinav2196
    hi there I'm having an issue creating and inserting into table from terminal but can do it from workbench
    It should be a syntax problem but i think i'm using the correct syntax
    can anyone help?
    extsalt
    @extsalt
    @abhinav2196 share your DML.
    lokendra singh chouhan
    @loks15
    走你飛艇
    @gofighting123

    hi there, i had a problem with my sql, it's simple but i can't figure out why it can excute sometimes but offten can't excute successfully.

    DELETE FROM general_log where sqltext='SET NAMES utf8' LIMIT 240

    the error is

    [Err] 1206 - The total number of locks exceeds the lock table size
    走你飛艇
    @gofighting123
    already done with that issue, thanks.
    Syam Danda
    @syamdanda
    Hi everyone, check this repository if someone is looking to have web based tool to access your mysql database.. or you guys can contribute for quick releases.
    https://github.com/syamdanda/mySequelWeb
    nowfal-n
    @nowfal-n
    Hi, Can someone help me out with this query?
    CREATE TABLE nflfeedjoblog (
    BatchId int(30) NOT NULL AUTO_INCREMENT,
    processDate datetime DEFAULT NULL,
    status smallint(6) DEFAULT '0',
    pmid int(11) DEFAULT '0',
    NFLTransactionId int(30) DEFAULT '0',
    PRIMARY KEY (BatchId),
    KEY NewIndex1 (BatchId,NFLTransactionId),
    KEY NewIndex2 (processDate)
    ) ENGINE=MyISAM DEFAULT CHARSET=latin1
    I don't understand what "KEY NewIndex1 (BatchId,NFLTransactionId)" tjhis does ?
    Sorry if this sounds dumb but Im fairly new to databases. Thanks in advance.
    Emiliano Heyns
    @retorquere
    Is this proper for for IN queries: 'DELETE FROM items WHERE itemKey in (?)', [['a', 'b']]), or should I use 'DELETE FROM items WHERE itemKey in ?', [['a', 'b']])?
    lokendra singh chouhan
    @loks15
    Emiliano Heyns
    @retorquere
    I'm well aware of those, which is why I want to use parametrized queries, I just don't know a) whether mysqljs supports array values, and b) whether I should use IN ? or IN (?) when I use them.
    Alexander Tunick
    @AlexanderTunick

    Hi guys! Having made a simple query with count() operator i'm obtaining badly formatted response where the value's name in object is a part of my query that looks stupid

    [ RowDataPacket { 'count(distinct `jpp`.`job_position_id`)': 10 } ]

    could I somehow change it?
    Thanks.

    it would be great to have something like:
    [10]
    or
    [{'result': 10}]
    or
    [{'': 10}]
    herrifransisca
    @herrifransisca

    hello everyone, /\

    I'd like to make an app with nodejs, mysql

    1. what driver/module should I use ?
      (if mongodb, I use "mongoose")

    2. I'd like to deploy it to heroku, where should I host the database ?
      (if mongodb, I use "mlab")

    thank you very much for the guidance

    Nirvana
    @Himly1
    Hello
    Why this sql cannot run ?
    select * from project_application_records par inner join (select * from project_version pv where pv.project_id = par.project_id order by version desc limit  1) as prv
    Here is the error
    [42S22][1054] Unknown column 'par.project_id' in 'where clause
    Here is the table struct
    id    bigint(20)    NO    PRI        auto_increment
    application_info    json    NO    ""        ""
    application_method    int(11)    NO    ""        ""
    created_at    datetime    NO    ""        ""
    process_instance_id    varchar(255)    NO    ""        ""
    status    int(11)    NO    ""        ""
    updated_at    datetime    NO    ""        ""
    dynamic_form_id    bigint(20)    NO    MUL        ""
    project_id    bigint(20)    YES    MUL        ""
    user_id    bigint(20)    YES    MUL        ""
    real_time_application_status    varchar(255)    YES    ""        ""
    lokendra singh chouhan
    @loks15
    Different Types Of SQL Joins https://www.technolush.com/blog/sql-joins
    Panyu
    @MarvellousBaby
    hello everyone'
    [ERROR] Found 1 prepared transactions! It means that mysqld was not shut down properly last time and critical recovery information (last binlog or tc.log file) was manually deleted after a crash. You have to start mysqld with --tc-heuristic-recover switch to commit or rollback pending transactions.
    2019-05-13 16:41:21 140652249397056 [ERROR] Aborting