List:General Discussion« Previous MessageNext Message »
From:Thiyaghu CK Date:January 8 2010 1:29pm
Subject:Re: Another Inserting Multiple Values with Set Problem
View as plain text  
Hi Victor,

Take out the double quotes from[ "('Small,Medium,XSmall')",
"('teal_E2725B,black_0000FF,yellow_9ACD32')"]. Its working fine for me.

mysql> insert into products (sizes, colorsShadesNumbersShort)
values(('Small,Medium,XSmall'), ('teal_E2725B,black_0000FF,yellow_9ACD32'));
Query OK, 1 row affected (0.05 sec)

mysql> select * from products;
+---------------------+----------------------------------------+
| sizes               | colorsShadesNumbersShort               |
+---------------------+----------------------------------------+
| XSmall,Small,Medium | black_0000FF,yellow_9ACD32,teal_E2725B |
+---------------------+----------------------------------------+
5 rows in set (0.01 sec)

Regards,
Thiyaghu CK
www.mafiree.com

On Fri, Jan 8, 2010 at 2:27 PM, Victor Subervi <victorsubervi@stripped>wrote:

> On Fri, Jan 8, 2010 at 2:26 AM, Thiyaghu CK <theyahoock@stripped> wrote:
>
>> Hi Victor,
>>
>> You have given space after the comma(shown here: ('Small, Medium,
>> XSmall')). Take out the space and try, it will work.
>>
>> Example:
>>
>> mysql> insert into products(sizes) values ('Small,Medium,small,medium');
>> Query OK, 1 row affected (0.05 sec)
>>
>
> insert into products (SKU, Category, Name, Title, Description, Price,
> SortFactor, Availability, OutOfStock, Weight, ShipFlatFee, ShipPercentPrice,
> ShipPercentWeight, sizes, colorsShadesNumbersShort) values("prodSKU1",
> "prodCat1", "name1", "title1", "descr", "123.45", "500", "1", "0", "2.5",
> "10.00", "5", "2", "('Small,Medium,XSmall')",
> "('teal_E2725B,black_0000FF,yellow_9ACD32')");
>
> mysql> select sizes from products;
> +--------+
> | sizes  |
> +--------+
> | Medium |
> +--------+
>
> 1 row in set (0.00 sec)
>
> mysql> select colorsShadesNumbersShort from products;
> +--------------------------+
> | colorsShadesNumbersShort |
> +--------------------------+
> | black_0000FF             |
> +--------------------------+
>
> 1 row in set (0.00 sec)
>
>
> It only entered one of each!! Please help.
> V
>

Thread
Another Inserting Multiple Values with Set ProblemVictor Subervi6 Jan
Re: Another Inserting Multiple Values with Set ProblemVictor Subervi6 Jan
  • Re: Another Inserting Multiple Values with Set ProblemMichael Dykman6 Jan
    • Re: Another Inserting Multiple Values with Set ProblemVictor Subervi6 Jan
Re: Another Inserting Multiple Values with Set ProblemVictor Subervi6 Jan
  • Re: Another Inserting Multiple Values with Set ProblemMichael Dykman6 Jan
    • Re: Another Inserting Multiple Values with Set ProblemVictor Subervi6 Jan
      • Re: Another Inserting Multiple Values with Set ProblemCarsten Pedersen6 Jan
        • Re: Another Inserting Multiple Values with Set ProblemVictor Subervi8 Jan
          • Re: Another Inserting Multiple Values with Set ProblemThiyaghu CK8 Jan
            • Re: Another Inserting Multiple Values with Set ProblemVictor Subervi8 Jan
              • Re: Another Inserting Multiple Values with Set ProblemThiyaghu CK8 Jan
                • Re: Another Inserting Multiple Values with Set ProblemVictor Subervi8 Jan
Re: Another Inserting Multiple Values with Set ProblemVictor Subervi6 Jan