How to constraint column of MySQL?
like: create table test( score integer unsigned between 1 and 100 ... ); Is it possible to do this in MySQL? ...
like: create table test( score integer unsigned between 1 and 100 ... ); Is it possible to do this in MySQL? ...
Hey, I need som help to list my added dates from database, and split it into their added month. I have no clue on how to do it... Soe can someone please show me examples, or maybe some tutorials how to do? Thx ...
I am trying to install the mysql++ in Code::Blocks, but When I try to run the example code I get this error: undefined reference to __imp___ZN7mysqlpp10ConnectionC1Eb What I am doing wrong? ...
Hello guys, I need advises and want to share my experience about Query Optimization. This week, I found myself stuck in an interesting dilemma. I'm a novice person in mySql (2 years theory, less than one practical) Environment : I have a table that contains articles with a column 'type', and another table article_version that contain a...
What's the difference between DELETE FROM table_a and TRUNCATE TABLE table_a in MySQL? ...
Hi all, In MySQL, what is the preferred column type for storing a product's price (or currencies in general)? Google learned me DECIMAL of FLOAT is often used, but I wonder which one is better. I'm storing prices ranging from 0.01 to 25.00. Of course higher values could also be possible. (Note: I'm not asking for copy-pasta code, I'm ...
coming from php and Mysql i know how its best done in php but im not realy sure were to start with ASP.NET, can anyone give me any pointers? ...
Hi! Do you know any easy way to remove (or replace) all non alphanumeric characters from varchar variable in Mysql? something like String's replaceAll("[^a-zA-Z0-9]", "I") in Java ('I' is my special character but "" would be also good ) ...
Hi, In the Spring Framework manual they state that for a PROPAGATION_REQUIRES_NEW the current transaction will be suspended. What does that "suspended transaction"? The timer for the timeout stops counting on the current transaction? What are the actual implication of such suspension? Thank you, Asaf ...
I want to write a SQL statement something like insert into mytable column1=value1 and ((column2,column3,column4) (select filed1, filed2,filed3 from anothertable where filed4=a_varible)) I am using Mysql. The statement above only expresses what I am going to achieve. Is it possible? Is there a way to achieve this? ...
Hi all!, I'm building a searchfunctionallity where a user can select the different libraries to search in with the provided keywords. Also the AND operator is supported. My problem is that when I try to search for information it gets somehow multiplied or it gets increased exponential?? I'm using a MySQL database and PHP to process the...
I'm getting � this character in my facebook app instead of "£"- I checked the mysql db and the character is being stored as £. How do i fix this? This has never happened to me before - I'm using PHP as well. ...
Does Pentaho's ETL system, Kettle (http://kettle.pentaho.org/) have a plugin to accept information from JMS messages? I'd like to set up a job that can read messages each containing a hash, extract certain data, and stuff it into a table. Has anyone had any experience with this? Is this a good idea? Any pitfalls? Thanks. ...
So I have a question regarding the best practice for a PHP page inserting a new row into a table. There are some required fields (aka NOT NULL) and some optional fields (can be NULL). Is it better to insert everything with one query, or just do the required fields, get the inserted ID and update the other fields with one or more other ...
I'm trying to import a large number of products from a DB into Magento. The DB has many different product categories, which I've recreated within Magento. However, when importing the products via a CSV, you must list the category ID rather than the name. Is there any way to bring up a list like the following: id | category 1 | pies 2 | ...
I'm writing an application which tracks views of various items across time, and I've hit a bit of a snag. I need to get the difference in views between two adjacent updates. The updates are identified by a UNIQUE key, containing the columns time and id. How would I be able to do this, without running multiple queries? SELECT updates.vi...
Building a form, I'm wondering if there is any significant advantage to having the query string show values in a more human readable format. example index.php?user=ted&location=newyork&...and so on rather than index.php?user=23423&location=34645&... and so on On the one hand, having the query string a little more readable allows the ...
so i have 2 tables: -char (keeps information about the player) -special (its a rank for top mobs, so each line from this table is a record of all the players that killed a mob and the total time) here's a summary i wrote: ################## ## table char: ## ################# `char_id` - int(12) auto increment - primary key `type` - va...
I need to reset my table counter back to 0 - is there a MySQL command for this? ...
hi I am doing A query to get some product info, but there is something strange going on, the first query returns resultset fast (.1272s) but the second (note that I just added 1 column) takes forever to complete (28-35s), anyone know what is happening? query 1 SELECT p.partnumberp, p.model, p.descriptionsmall, p.brandname, sum(remainde...