Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Need SQL Help
Message
De
23/02/2001 08:37:34
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Titre:
Divers
Thread ID:
00478577
Message ID:
00478778
Vues:
35
What can do is to SELECT for the group and day you need into a cursor then do a SCAN to collect concetive times into an array with the PK of the begining of the time slot...



>Table1
>
>PK reskey resgrp time resused
>========================================
> 1 1 1 0700 F
> 2 1 1 0715 F
> 3 1 1 0745 F
> 4 1 1 0800 T
> 5 2 1 0700 T
> 6 2 1 0715 F
> 7 2 1 0730 F
> 8 10 5 0700 F
> 9 10 5 0715 F
>10 10 5 0730 T
>11 10 5 0745 T
>12 10 5 0800 F <=
>13 10 5 0815 F <=
>14 10 5 0830 F <=
>15 10 5 0845 F <=
>16 10 5 0900 T
>ETC...
>
>I need to be able to query the table for a set of time slots
>that equal some period (example 1 hour) for a given resgrp.
>The time slots have to be together.
>
>select * from table 1
>where resgrp = 5
>and resused=.f.
>and ?
>
>Thanks for any help
>Kirk
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform