Postoperative pain and labor pain are among the most prevalent and intense types of acute pain. Their effective management often requires the administration of parenteral analgesic mixtures combining opioids with local anesthetics. Since no ready-to-use commercial formulations are available and given the complexity and risk of error in their preparation, the Spanish Guide to Good Medication Preparation Practices in Hospital Pharmacy Services recommends their centralized compounding in clean rooms within the pharmacy department. The aim of this study is to describe the implementation experience of a computerized gravimetric control system for stock-prepared analgesic formulations and to assess its reliability and usefulness.
MethodA retrospective observational study was conducted including all analgesic units prepared in the Pharmacy Department between July 2024 and April 2025. Gravimetric control was performed using an electronic balance integrated into the Pharmasuite® software, which automatically calculated the concordance between theoretical and actual weight, generating alerts in case of deviations. Primary acceptance limits were set at ±1.5–1.7% depending on the formulation, based on previous experience and the consistency observed in earlier batches. A total of seven different formulations were analyzed.
ResultsDuring the study period, 1,460 units were prepared, corresponding to 238 batches. Five out of the seven formulations achieved 100% compliance with the acceptance limit. In the remaining formulations, the proportion of non-compliant units was below 1%. The mean relative standard deviation ranged from 0.189% to 0.338%, always below 0.5%, indicating high reproducibility. The mean actual weight was very close to the theoretical weight in all formulations. Units falling outside the acceptance range were individually discarded, and no complete batch had to be rejected.
ConclusionsThe implementation of computerized gravimetric control in the compounding of analgesic formulations proved to be an effective and safe strategy to ensure accuracy, detect errors, and reinforce traceability. The experience described represents a quality improvement tool that may be extrapolated to other centers.
el dolor posoperatorio y el asociado al parto constituyen 2 de los tipos de dolor agudo más prevalentes y de mayor intensidad. Su manejo eficaz requiere a menudo la administración de mezclas analgésicas parenterales, que combinan opioides con anestésicos locales. Al no existir formulaciones comerciales listas para su uso, y dada la complejidad y el riesgo de error en estas elaboraciones, la Guía de buenas prácticas de preparación de medicamentos en servicios de farmacia hospitalaria recomienda su elaboración centralizada en salas blancas de los servicios de farmacia. El objetivo de este trabajo es describir la experiencia de implantación de un control gravimétrico informatizado de formulaciones analgésicas elaboradas para stock y analizar su fiabilidad y utilidad.
Métodose realizó un estudio observacional retrospectivo de todas las unidades analgésicas preparadas en el servicio de farmacia entre julio de 2024 y abril de 2025. El control gravimétrico se llevó a cabo mediante una balanza electrónica integrada en el software Pharmasuite®, que calculaba automáticamente la concordancia entre el peso teórico y el real, generando alertas en caso de desviación. Los límites primarios de aceptación se fijaron en ±1,5–1,7% según la formulación, basándose en la experiencia previa y en la consistencia observada en lotes anteriores. Se analizaron un total de 7 formulaciones distintas.
Resultadosdurante el periodo de estudio se elaboraron 1.460 unidades, correspondientes a 238 lotes. Cinco de las 7 formulaciones presentaron un 100% de conformidad con el límite de aceptación. En el resto, el porcentaje de unidades no conformes fue inferior al 1%. La desviación estándar relativa media osciló entre 0,189 y 0,338%, siempre por debajo del 0,5%, lo que refleja una elevada reproducibilidad. El peso medio real fue muy próximo al teórico en todas las formulaciones. Las unidades fuera de rango fueron descartadas de forma individual y en ningún caso fue necesario rechazar un lote completo.
Conclusionesla implantación del control gravimétrico informatizado en la elaboración de formulaciones analgésicas ha demostrado ser una estrategia eficaz y segura para garantizar la precisión, detectar errores y reforzar la trazabilidad. La experiencia descrita constituye una herramienta de mejora de calidad extrapolable a otros centros.
Postoperative pain is one of the most common types of acute pain; it is typically temporary, predictable and potentially preventable. It is defined as pain experienced by a patient as a result of an underlying condition, the surgical procedure itself, complications arising from the procedure, or a combination of these factors. An estimated 30% to 80% of patients experience moderate-to-severe acute postoperative pain during the first 24 h following surgery, and approximately 2.7% still experience pain upon discharge from the hospital. Inadequate pain management may contribute towards the pain becoming chronic.1–4
Pain associated with childbirth is another significant example of acute pain, considered one of the most intense forms of pain a person can experience. It is caused by the uterine contractions, cervical dilation and vaginal distension necessary for the passage of the foetus. Only 15% of women describe the pain as minimum intensity, which highlights the need for effective analgesic strategies.5
Appropriate management of postoperative pain helps to speed up patients' recovery, reduce the incidence of complications, prevent unnecessary suffering and shorten hospital stays, thereby reducing healthcare costs.4,6 Effective analgesia requires initiation of treatment before pain sets in, as once established, it is more difficult to control. The analgesic regimen must be adjusted on an individualised and progressive basis, taking into account the specific characteristics of the pain (type, location, intensity and duration), to achieve maximum relief with minimum adverse effects.3,6,7
Pain has a complex pathophysiology involving numerous neurotransmitters. Its management requires a multidisciplinary approach and the use of drugs with different mechanisms of action. Opioids, such as morphine and fentanyl, are commonly used in the management of moderate-to-severe pain, either as monotherapy or, more frequently, in combination with local anaesthetics such as levobupivacaine and ropivacaine, or with non-opioid analgesics including paracetamol and non-steroidal anti-inflammatory drugs (NSAIDs). These combinations can be administered via various routes, such as oral, intramuscular, subcutaneous, intravenous, epidural or even intrathecal.4,8
In the absence of commercially available parenteral analgesic combinations, these admixtures must be prepared by healthcare professionals. Preparation may be performed either in clinical units immediately prior to administration or centrally within hospital pharmacy services. The Guide to Good Practices for the Preparation of Medicinal Products in Hospital Pharmacy Departments (GBPP) classifies these preparations as medium-risk. Therefore, it recommends centralised preparation within the hospital pharmacy department, in cleanroom facilities, under a laminar flow hood, and in a controlled environment.9,10
The preparation of parenteral admixtures constitutes a critical process, as dosing errors and errors in component selection continue to rank among the most frequent causes of medication-related adverse events.11,12 In recent years, the introduction of technology-assisted workflow systems (TAWS), which integrate barcode scanning, image capture and gravimetric verification, has demonstrated a significant reduction in errors compared to traditional manual processes, as well as an improvement in the traceability and standardisation of sterile preparations.11,13,14
Computerised gravimetric control is a widely used validation tool in the compounding of sterile solutions, particularly in parenteral nutrition and chemotherapy.15–19 Several studies indicate that it enables the detection of volume and dose deviations that cannot be identified through visual inspection, making it one of the primary methods of quantitative verification within these systems.20,21
From an economic perspective, integrated gravimetric verification also offers cost-effectiveness.22,23 The combination of its clinical impact and economic viability has led to the widespread adoption of gravimetry in hospitals.
In our pharmacy department, standardised analgesic formulations are regularly prepared for stock, intended for in-hospital treatment of moderate to severe pain due to surgery or childbirth, and used in intensive care units (ICUs), post-anaesthesia care units (PACUs) and the obstetrics department. These preparations include combinations of levobupivacaine or ropivacaine with fentanyl, as well as solutions of morphine or ropivacaine as monotherapy.
The epidural route is used for combinations of local anaesthetics with fentanyl and for ropivacaine as monotherapy, but the morphine solution is administered intravenously. The final containers consisted of 100 ml or 200 ml Micrel bags.
As part of the quality control process for the finished product, a computerised gravimetric control system was implemented for these analgesic formulations and integrated into the software used in the pharmaceutical technology and drug preparation department (Pharmasuite®). This procedure uses an electronic balance and the density of the solution to check the accuracy of the prepared volume by calculating the final weight of the formulation.24
The aim of this study was to describe the experience of implementing computerised gravimetric control in the pharmacy department and to analyse its reliability and usefulness by studying the batches prepared over a 9-month period.
MethodA retrospective observational study was conducted on the computerised records of analgesic formulations prepared for stock in our hospital's pharmacy department between July 2024 and April 2025.
We included 7 standardised analgesic formulations prepared for stock, intended for epidural or intravenous administration: combinations of levobupivacaine or ropivacaine with fentanyl, as well as solutions of morphine or ropivacaine for monotherapy.
All preparations compounded were recorded in the software of the pharmaceutical technology and drug preparation unit (Pharmasuite®), ensuring full traceability. Each standard operating procedure (SOP) included information on dosage form, route of administration, components and quantities, equipment, working protocol, risk level according to the GBPP risk matrix, Anatomical Therapeutic Chemical (ATC) group, packaging material, storage, shelf life, and quality controls.
All formulations were prepared under pharmaceutical supervision by nursing staff in a cleanroom facility, under a horizontal laminar flow hood and following the established SOPs. The necessary medication and consumables were provided by pharmacy technicians, who verified that dispensed batches matched the respective SOP. In the case of narcotics, the required volume for each batch was dispensed in a controlled manner, corresponding exactly to the total volume needed for the units to be prepared, so as to avoid surpluses and ensure safe use. Furthermore, we avoided simultaneous preparation of batches corresponding to different formulations, in order to minimise the risk of errors.
Automated gravimetric control of all analgesic units was carried out under pharmaceutical supervision. Each unit was weighed on a Cobos® precision balance, model AJH-2200 CE (resolution: 0.01 g; operating range: 10–2200 g), previously integrated with the department's software application.
As density values were not available in the Summary of Product Characteristics (SmPC), they were requested directly from the manufacturing laboratories. Densities are expressed in g/ml: fentanyl (Fentanilo Kalceks Ever Pharma® 50 μg/ml, C.N. 729355), 1.100; levobupivacaine (Levobupivacaine Altan® 1.25 mg/ml, C.N. 700801), 1.005; morphine (Morphine B. Braun® 20 mg/ml, C.N. 720313), 1.0083; ropivacaine (Ropivacaine Fresenius Kabi® 10 mg/ml, C.N. 676516), 1.005; and 0.9% saline solution, 1.007.
The empty bags used for the various formulations were also weighed: 23.80 g (Micrel® Yellow Full Set 200 ml bag, REF. KE1.EE.190.0) and 20.05 g (Micrel® Yellow Mini Full Set 100 ml bag, REF. KE1.EE.167.0) for epidural administration and 19.70 g (Micrel® Mini Full Set 100 ml bag, REF. KE1.EE.177.9) for intravenous solutions.
The software system recorded the individual weight of each unit as part of the batch quality control. It automatically compared the actual mean weight of the batch with the established theoretical weight and issued an alert in the event of deviations outside the accepted range.
Individual primary acceptance limits were defined for each formulation (± 1.5–1.7%), established based on volume and composition, and determined from the maximum and minimum values accepted in previously produced batches. To this end, the 20 batches of each formulation were analysed prior to the implementation of this control system.
Units outside the range were discarded individually. If more than two non-compliant units were found in the same batch, the responsible pharmacist assessed the cause of the error and the potential complete rejection of the batch.
For each unit produced, the following variables were recorded:
- •
Actual weight (g)
- •
Absolute difference (g) from the mean batch weight
- o
Difference (g) = actual weight − mean batch weight
- •
Relative difference (%) from the mean batch weight
Mean weight (g) and relative standard deviation (RSD, %) were calculated for each batch as an indicator of the consistency of the manufacturing process. The RSD, also known as the coefficient of variation (CV), is a statistical measure that quantifies the relative variability or dispersion of a data set in relation to its mean. A high RSD indicates a wide dispersion of values relative to the mean, whilst a low RSD reflects greater homogeneity and good reproducibility, with the data closely clustered around the mean. RSD values below 10–15% are considered acceptable, although the exact threshold will depend on the type of study. It is defined as the ratio of the standard deviation to the arithmetic mean, expressed as a percentage, and its formula is as follows:
ResultsA total of 1460 units were compounded during the study period, distributed across 238 batches of 7 different analgesic formulations. The exact composition of each formulation is detailed in Table 1.
Standardised analgesic formulations included in the study and their composition.
| Formulation (bag and volume) | Dosage form/Route | Composition |
|---|---|---|
| Levobupivacaine 1.2 mg/ml + fentanyl 2 μg/ml(Micrel® Yellow Mini Full Set 100 ml bag) | Solution/epidural | Levobupivacaine 1.25 mg/ml………96 mlFentanyl 50 μg/ml……………………4 ml |
| Levobupivacaine 1.2 mg/ml + fentanyl 2 μg/ml(Micrel® Yellow Full Set 200 ml bag) | Solution/epidural | Levobupivacaine 1.25 mg/ml………192 mlFentanyl 50 μg/ml………..………….8 ml |
| Morphine 1 mg/ml(Micrel® Mini Full Set 100 ml bag) | Solution/intravenous | Morphine 2%………………………..……5 mlSodium chloride 0.9%………..………95 ml |
| Ropivacaine 2 mg/ml(Micrel® Yellow Full Set 200 ml bag) | Solution/epidural | Ropivacaine 10 mg/ml………..……40 mlSodium chloride 0.9%……….…….160 ml |
| Ropivacaine 0.75 mg/ml + fentanyl 2 μg/ml(Micrel® Yellow Mini Full Set 100 ml bag) | Solution/epidural | Ropivacaine 10 mg/ml……….………7.5 mlFentanyl 50 μg/ml…….……….…….4 mlSodium chloride 0.9%………..……….88.5 ml |
| Ropivacaine 1.2 mg/ml + fentanyl 2 μg/ml(Micrel® Yellow Mini Full Set 100 ml bag) | Solution/epidural | Ropivacaine 10 mg/ml….…………12 mlFentanyl 50 μg/ml……………..…….4 mlSodium chloride 0.9%………..………84 ml |
| Ropivacaine 2 mg/ml + fentanyl 2 μg/ml(Micrel® Yellow Full Set 200 ml bag) | Solution/epidural | Ropivacaine 10 mg/ml….…..…….40 mlFentanyl 50 μg/ml.……………………8 mlSodium chloride 0.9%……….…….152 ml |
Computerised gravimetric control was used for 100% of the units produced. Fig. 1 shows the percentage differences between the actual weight and the theoretical weight of all the units prepared. The variability observed remained within the established acceptance limits for each formulation, with no evidence of systematic accumulation of errors in any of them.
Percentage differences between actual and theoretical values.
Acceptance limits for each formulation (upper and lower red lines) and the individual difference values (%) between the actual and theoretical weights for each unit produced (green lines). Each separator point indicates the transition between different formulations, represented to the left of the corresponding marker: 1) levobupivacaine 1.2 mg/ml + fentanyl 2 μg/ml (100 ml); 2) levobupivacaine 1.2 mg/ml + fentanyl 2 μg/ml (200 ml); 3) morphine 1 mg/ml; 4) ropivacaine 2 mg/ml; 5) ropivacaine 0.75 mg/ml + fentanyl 2 μg/ml; 6) ropivacaine 1.2 mg/ml + fentanyl 2 μg/ml; 7) ropivacaine 2 mg/ml + fentanyl 2 μg/ml.
The actual mean weight of the prepared units showed close agreement with the theoretical weight for all formulations. The mean RSDs ranged from 0.189% to 0.338%, indicating high consistency and precision in the preparation process (Table 2).
Results of computerised gravimetric control by formulation.
| Formulation (bag and volume) | No. of units | No. of batches | 1st acceptance limit (%) | Theoretical weight (g) | Total actual mean weight (g) | Mean RSD (%) | Accepted bags (%) |
|---|---|---|---|---|---|---|---|
| Levobupivacaine 1.2 mg/ml + fentanyl 2 μg/ml (100 ml) | 464 | 54 | 1.7 | 120.93(121 ± 2) | 121.48 | 0.269 | 99.57 |
| Levobupivacaine 1.2 mg/ml + fentanyl 2 μg/ml (200 ml) | 322 | 63 | 1.5 | 225.56(225.5 ± 3.5) | 225.51 | 0.223 | 99.69 |
| Morphine 1 mg/ml (100 ml) | 112 | 22 | 1.7 | 120.41(121 ± 2) | 121.51 | 0.225 | 100 |
| Ropivacaine 2 mg/ml (200 ml) | 33 | 11 | 1.5 | 225.12(225.5 ± 3.5) | 225.54 | 0.189 | 100 |
| Ropivacaine 0.75 mg/ml + fentanyl 2 μg/ml (100 ml) | 149 | 28 | 1.7 | 120.76(121 ± 2) | 121.39 | 0.338 | 100 |
| Ropivacaine 1.2 mg/ml + fentanyl 2 μg/ml (100 ml) | 302 | 42 | 1.7 | 121.10(121 ± 2) | 121.65 | 0.316 | 100 |
| Ropivacaine 2 mg/ml + fentanyl 2 μg/ml (200 ml) | 78 | 18 | 1.5 | 225.86(225.5 ± 3.5) | 225.58 | 0.242 | 100 |
RSD: Relative standard deviation (coefficient of variation).
Primary acceptance limits were established individually for each formulation. The theoretical weight was calculated taking into account the density of the components and the weight of the empty bag (the theoretical weight is shown in brackets together with the acceptance limits established in the SOP). The total actual mean weight of each formulation was calculated as the arithmetic mean of the individual actual weights of all units produced and weighed during the study period.
In 5 of the 7 formulations, 100% of the units remained within the established primary acceptance limit. A small percentage of levobupivacaine 1.2 mg/ml + fentanyl 2 μg/ml formulations were outside the acceptance range: 0.31% in the 200 ml bags and 0.43% in the 100 ml bags. A total of 3 non-compliant units were identified, which were individually discarded as they belonged to different batches. No full batches were rejected.
There was no pattern of systematic deviation associated with a specific formulation.
DiscussionPain management in hospitalised patients, particularly in post-operative, obstetric or palliative care settings, frequently requires parenteral analgesic mixtures. These combinations, which typically contain opioids such as fentanyl alongside local anaesthetics such as levobupivacaine or ropivacaine, allow for more precise pain control and better adaptation to the patient's clinical needs.
Centralised preparation of these formulations in the hospital's pharmacy department improves patient safety by ensuring correct preparation, stability and accurate dosing, particularly in mixtures containing narcotics.9,25
Although gravimetric control has been more widely implemented for chemotherapy preparations, and paediatric compounding,15,16 and several publications have validated its use in parenteral nutrition,17–19 there is limited evidence regarding its application for the validation of stock analgesic formulations intended for intravenous or epidural administration. In our department, implementation has proven to be an effective measure for traceability and safe handling of these high-risk drugs, particularly those administered via the epidural route. This is in line with the recommendations of the Institute for Safe Medication Practices (ISMP) and the Spanish Society of Hospital Pharmacy (SEFH).26–29
Previous work has highlighted the importance of implementing traceability systems and safe drug preparation in cleanroom environments, which supports the need to extend these controls to a broader range of pharmaceutical formulations.30 Furthermore, studies such as the MEDPAIN project and national surveys conducted by the Spanish Pain Society (SED in Spanish) show considerable variability among hospitals in the use of analgesic admixtures for post-operative pain management in Spain. This variability reinforces the need to establish reliable control tools, such as the gravimetric system used in this study.4,8
In this context, computerised gravimetric control is a useful alternative for validating the quality of the final product. Fig. 1 shows that the values remain largely within the defined acceptance limits, indicating adequate reproducibility of the process. In fact, all formulations analysed showed a mean RSD of less than 0.5%, reflecting high accuracy and low variability in the compounding process. The utility of the system for early error detection was demonstrated through the identification of units outside the predefined limits, which were subsequently discarded and assessed by the designated pharmacist. The implementation of this control system has led to a significant improvement in safety and quality through the provision of objective and systematic verification.
At present, there is no published evidence establishing acceptance limits for the gravimetric control of analgesic formulations. In other settings, such as parenteral nutrition, acceptance limits of up to 5% have been reported, whilst for parenteral antineoplastic preparations, acceptance limits typically range between 5% and 10%.16,31,32 One recommendation is to begin with tolerance limits of ±5%.20 However, in the present study, more stringent primary acceptance limits (±1.5–1.7%) were established, based on the department's previous experience and the consistency observed in previously prepared batches.
This is one of the key points, as the literature highlights the importance of correct equipment calibration and the definition of tolerances to ensure that gravimetric control acts as an effective safeguard against errors in the preparation of parenteral admixtures.20,21
Among the main initial challenges were obtaining drug density values, which were not systematically available in the SmPC, and training the staff involved in the new procedure. These were resolved through consultation with manufacturers to obtain density data and the delivery of dedicated training sessions for nursing staff and pharmacy technicians, covering system operation, interpretation of results, and actions in the event of deviations. An initial adaptation period was required to integrate gravimetric control into the routine workflow without a significant impact on processing times.
This study has some limitations. Firstly, its retrospective, single-centre observational design may limit the generalisability of the results to other settings with different workflows, equipment or volume of activity. Secondly, the causes of the deviations detected were not systematically analysed; as a future improvement, it would be interesting to investigate error detection in greater depth to prevent their recurrence and further optimise the process. However, these limitations do not invalidate the results obtained; rather, they reflect a real-world clinical practice and support the usefulness of computerised gravimetric control as a tool for improving quality and safety, given that only 0.2% of the total prepared units needed to be discarded.
In conclusion, the implementation of a computerised gravimetric control system has allowed validation of the correct preparation of standardised stock analgesic formulations in our hospital, improved patient safety, and strengthened process traceability. This experience may serve as a reference for other centres seeking to advance towards safer preparation of this type of medication.
Declaration of authorship and originalityAll authors have participated in the drafting, revision and approval of the final version of this manuscript.
Responsibility and transfer of rightsAll authors accept the responsibilities defined by the International Committee of Medical Journal Editors (available at http://www.icmje.org/).
The authors hereby assign, in the event of publication, the exclusive rights of reproduction, distribution, translation and public communication (by any means or medium, whether audio, audio-visual or electronic media) of our work to Farmacia Hospitalaria and, by extension, to the SEFH. To this end, a letter of assignment of rights was signed at the time of submission of the manuscript via the online manuscript management system.
CRediT authorship contribution statementSandra Caíña-López: Writing – review & editing, Writing – original draft, Visualisation, Validation, Methodology, Investigation, Formal analysis, Data curation, Conceptualization. María Carmen Dávila-Pousa: Writing – review & editing, Writing – original draft, Validation, Methodology, Investigation, Formal analysis, Conceptualization.
FundingNone declared.
None declared.








