Data dodania Pytanie
2017-06-08 09:06 Average a certain column value in MySQL »
I have this table structure: id | code | rating 1 | 300 | 25 2 | 302 | 35 3 | 100 | 50 4 | 100 | 30 5 | 200 | 40 6 | 103 | 4...
(4) odpowiedzi
2017-06-08 06:06 Why Mysql is not handling case sensitive cases »
When I test below sql queries: 1. SELECT * FROM table WHERE username='username' AND password = 'password'; 2. SELECT * FROM table WHERE...
(2) odpowiedzi
2017-06-08 06:06 Order fields in UNION query »
I am trying to make an union query in MySQL between two queries. But, each query is ordered by a different field, and I need both queries in only one...
(1) odpowiedzi
2017-06-07 18:06 MySQL 'SHOW TABLES' Returns count instead of list (Python) »
I'm troubleshooting a script I am using to query the database. To make sure I had everything working right I stripped it down to a simple 'SHOW TABLES...
(1) odpowiedzi
2017-06-07 13:06 How to order by multiple timestamp fields and return them in chronological order? »
I have a table of posts (news) but they can have different date attributes and some of them may be unset (0). I want to order DESC on all fields and t...
(1) odpowiedzi
2017-06-07 12:06 Jooq 3.9 doesn't link MySQL columns to enums »
I am updating jooq from version 3.4.1 to 3.9.3 and noticed that models for tables that have enum fields in MySQL 5.6 database are generated with Strin...
(0) odpowiedzi
2017-06-07 11:06 Extracting a list of products bu category using doctrine »
I want to extract a list of products by given category, I dont know how to do that! I have found findAll which return all products in database should ...
(1) odpowiedzi
2017-06-07 07:06 Rails 3.2 : Duplicate entry for key index in mysql? »
I am using rails 3.2. Here! I am facing a problem, stats below. I am having two model classes RequestedTrip and TagTrip. Here! are two other models R...
(1) odpowiedzi
2017-06-06 15:06 Converting days to seconds in MySQL »
I need to convert the following column into seconds: +----------------------+ | duration | +----------------------+ | 00:15:52.22 ...
(2) odpowiedzi
2017-06-06 14:06 reuse mysql query code among few methods in same controller - Laravel 5.4 »
I have few queries which I would like to use it to few methods in the same controller.for example below code: $lastlogin = User::select('lastlogin')-...
(2) odpowiedzi
2017-06-06 11:06 Select 3 random Words (records) - one of each letter count »
I have a table with lots of words and also a field that holds the number of letters for each word. EDIT: The example data set below is just showing t...
(1) odpowiedzi
2017-06-06 00:06 Recursive Loop - Parent/Child Tree »
I'm trying to recursively loop through and return all child_id's that have the root element of 9. The structure: +-- 9 | +-- 8 | +-- 17 ...
(1) odpowiedzi
2017-06-05 18:06 Using select query with like operator and parameters in java »
I want to write this query: SELECT * FROM products WHERE name LIKE '%?%' OR description LIKE '%?%' and execute it through java in spring web appli...
(1) odpowiedzi
2017-06-05 10:06 Laravel development: Implication when creating MySQL database manually »
I'm in the process of building a Laravel application and I started with the database design. I implemented this directly on the commandline (mysql). ...
(1) odpowiedzi
2017-06-05 06:06 What difference between »
I have first query select count(*) from `order` where marketer_id = 75 and HandleStatus != -1 and (Created_at BETWEEN '2017-05-01' AND '2...
(3) odpowiedzi
2017-06-04 20:06 MySQL: Make a blog-style page with different data types at different points »
I'm trying to develop something similar to this with PHP and MySQL: http://a-bittersweet-life.tumblr.com/ I'd like to make a page that is mostly made...
(3) odpowiedzi
2017-06-04 10:06 How to get one records that sorted by date »
I have a table like this: id product_id price date 1 1001 100 2017-05-29 2 1005 101 2017-03-30 3 10...
(2) odpowiedzi
2017-06-04 03:06 Group records by day including days in between that contain no records in MySQL »
I have to display how many votes were issued on each day (from the first vote, until the last vote) users voted for poll 2. My current query works fi...
(1) odpowiedzi
2017-06-03 20:06 How to set a recursive steps counter using MySQL data in PHP »
So, I'm creating a mini strategy game for fun, and stumbled upon an issue I can't really sort out. I thought it would be easy, but seems I was wrong,...
(1) odpowiedzi
2017-06-03 13:06 Slow performance MySql query, alternatives / suggestions? »
I'm implementing a search filter page in my coin website but it's quite slow now that I have many entries: Here is the query when no filter is selec...
(3) odpowiedzi
2017-06-03 07:06 How to add case statement to add break after every record? »
There should be a break after every row LIKE 'A%' when find next records of LIKE 'B%'. $stmt = $con->prepare("SELECT * FROM fistevent WHERE Event...
(3) odpowiedzi
2017-06-03 04:06 MySQL float type range and precision confusion »
I'm learning MySQL and having problem with float's range and precision. From the mannual: For FLOAT, the SQL standard permits an optional specifi...
(1) odpowiedzi
2017-06-02 17:06 Sorting Data in Table by Column mysql and wordpress »
I am trying to sort the table by scores in ascending order. Here is the table : Here is the code I'm using $sql = "SELECT * FROM scores"; $myD...
(1) odpowiedzi
2017-06-02 13:06 Entrust with Laravel - Eloquent queries with conditional roles »
I'm having single User eloquent model in my Laravel App: I'll be using Entrust for roles. Users can have multiple roles. I already managed to get th...
(0) odpowiedzi
2017-06-02 11:06 mySQL: Finding average after removing top and bottom nth% of data »
I have a table with 3 columns: list_num, sales_price, and days_on_market I want to run one query that will output a single number for the average of ...
(1) odpowiedzi
2017-06-02 08:06 SQL - Add up column value singletable »
I have a table Like This Id|purchase_date | Purchase_price 1 |02-May-17 |$10.00 2 |02-May-17 |$20.00 3 |02-May-17 |$30.00 I want to wri...
(3) odpowiedzi
2017-06-02 01:06 SQL: Select rows that were not selected in a previous query »
SELECT * FROM table ORDER BY id ASC Will output the full table: id name weight -- ---- ------ 1 XXL 450 2 L 20 3 XL 30 4 XXL 875 5 S 2 ...
(2) odpowiedzi
2017-06-02 00:06 Select where max Mysql »
help please make sql select to database. There are such data. My table is: id news_id season seria date_update ---|------|---------|-----|-----...
(2) odpowiedzi
2017-06-01 16:06 SQL, convert integer for Timestamp subtraction »
Assume we have a relation R(A, B), with A contains int values and B contains Timestamps. We have to calculate: (time in B in minutes) - (int to minut...
(1) odpowiedzi
2017-06-01 12:06 Return Value from sql commands »
I am currently using the SQL command Select * from where name='john' Is it possible to return 20 no matter the query, for example Select * from wh...
(3) odpowiedzi
2017-06-01 08:06 Use AJAX to make a database query on Node.js »
I'm using Node.js as server with Mysql as database for storing logged in usernames. Can I use AJAX to make a sql database query and return the list of...
(1) odpowiedzi
2017-06-01 06:06 Obtaining database joined table with limit »
Ive been trying to join two tables but only showing a limited amount (2) of results from the joined table. Unfortunately I havent been able to obtain ...
(3) odpowiedzi
2017-05-31 22:05 Mysql order by many columns then randomize »
I have a query ordered by 4 columns with asc or desc. I would like order the resulting rows random if there are two rows with equals values. I.E. (wi...
(0) odpowiedzi
2017-05-31 15:05 Use COALESCE within SUM in MySQL SELECT statement »
I have the following tables: Table users id name base_discount 1 jack 10 2 michael 20 3 richard 30 Table item id name category...
(1) odpowiedzi
2017-05-31 15:05 SQL Order By month name chronologically instead of alphabetically »
I would like to get the month names to be in chronological order instead of alphabetically ordered. Here is my Sql code. SELECT month, sum(total) F...
(3) odpowiedzi