|
|
|
Uniq Index Uniq constraint
|
|||
|---|---|---|---|
|
#18+
Vopros Mozet li tokoy SQL Statement garnatirovat Unique of row ??? Insert Into Htransactions (UserID, PurposeID, DateCreated, ChatID) Select @UserID, 1, getdate(), @ChatID From Htransactions where TranID = @ChatID And Not exists(Select * from Htransactions where ChatID = @ChatID ) V tableze TranID uniq index ChatID pole kotoroe ukazivaet na druguy stroku v etoy tableze ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 15.08.2002, 16:02:06 |
|
||
|
Uniq Index Uniq constraint
|
|||
|---|---|---|---|
|
#18+
Какие-то у меня смутные подозрения, что такой запрос будет вставлять только одинаковые строки. ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 15.08.2002, 16:08:11 |
|
||
|
Uniq Index Uniq constraint
|
|||
|---|---|---|---|
|
#18+
net systema takaia Create table Htransactions ( TranID int not null identity, UserID int, PurposeID int ChatID int ) PurposeID opredeliaet tip stroki dopustim esli eto 1 to ego ChatID = 0, A esli PurposeID = 2 to ChatID ukazivaet na stroky s TranID i PurposeID = 1 TranID, UserID, PurposeID, ChatID 1 245 1 0 2 245 2 1 ... |
|||
|
:
Нравится:
Не нравится:
|
|||
| 15.08.2002, 16:14:22 |
|
||
|
|

start [/forum/topic.php?fid=46&msg=32043644&tid=1821098]: |
0ms |
get settings: |
8ms |
get forum list: |
19ms |
check forum access: |
2ms |
check topic access: |
2ms |
track hit: |
41ms |
get topic data: |
7ms |
get forum data: |
2ms |
get page messages: |
26ms |
get tp. blocked users: |
1ms |
| others: | 205ms |
| total: | 313ms |

| 0 / 0 |
