Neither comes first. In any application more complex that a "hello world" exercise, the first stage - and the most important - is the analysis. Define what the application has to do. Make sure you have a limit on the overall scope.

An important part of the design process is process modelling (or use case analysis if you are a troe object orientated person). This should identify the key data elements, and how they are used in all areas of your application. You may then want into somedata modelling - at a logical level first, then a physical data model. If you are using a relational database, this is often done using an E-R modelling tool - an Entity Relationship model.

Finally, design the various code sections to implement your process model and to interface with your (physical) data model.

As a rule of thumb, expect coding to take about 10% (the final 10% before testing) of the total project time.